﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Collections.Specialized;
using System.Collections;

namespace hedefgrup.reports.common
{
    public class ReportContext
    {
        private Hashtable _Storage = new Hashtable();

        public string CompatibleProjectName;
        public Report_Abstract Report;
        public string ApplicationPath;
        public string AudioFilesPath;
        public Tree Project;
        public Tree Questionnaire;
        public Tree Organization;
        public string TableName;
        public user User;

        public bool IsOfType<T>(object key)
        {
            return _Storage[key] != null && _Storage[key].GetType() == typeof(T);
        }

        public T Get<T>(object key)
        {
            return (T)_Storage[key];
        }

        public void Set(object key, object value)
        {
            _Storage[key] = value;
        }
    }
}
